export default {
  namespaced: true,
  state: {
    tabs: [],
    activeTabName: ''
  },
  mutations: {
    updateTabs (state, tabs) {
      state.tabs = tabs
    },
    updateAcTabName (state, name) {
      state.activeTabName = name
    },
    addTab (state, tab) {
      state.tabs.push(tab)
    },
    delTab (state, index) {
      state.tabs.splice(index, 1)
    }
  }
}
